package com.qef.com.mmovie.activity

import android.graphics.Color
import com.qef.com.mmovie.App
import com.qef.com.mmovie.R
import com.qef.com.mmovie.base.SimpleActivity
import com.qef.com.mmovie.utils.HindToolbar
import com.qef.com.mmovie.utils.SystemUtil
import com.qef.com.mmovie.utils.ToastUtil
import kotlinx.android.synthetic.main.auto_toolbar.*
import kotlinx.android.synthetic.main.layout_my_setting.*

class SettingActivity : SimpleActivity() {
    override fun getLayout(): Int {
        HindToolbar.setHintWindowTitle(window)
        return R.layout.layout_my_setting
    }

    override fun initEventAndData() {
        initView()
    }

    private fun initView() {
        toolbar.setNavigationIcon(R.mipmap.ic_arrow_back_white_24dp)
        toolbar.setNavigationOnClickListener({ onBackPressed() })
        toolbar.title = "设置"
        toolbar.setTitleTextColor(Color.WHITE)
        update_pwd.setOnClickListener {
            ToastUtil.showToast(this, "修改密码")
        }
        tv_version.text = "版本信息:" + SystemUtil.getAppVersion(App.getInstance())
    }
}

